package Day2_07_23;
import java.util.Scanner;

public class Change {
	public static void exchange() {
		int temp = 0;
		System.out.println("请输入要交换的数字：");
		Scanner sc = new Scanner(System.in);
		int num1 = sc.nextInt();
		int num2 = sc.nextInt();
		System.out.println("您输入的数字为：");
		System.out.println("num1:" + num1);
		System.out.println("num2:" + num2);
		temp = num1;
		num1 = num2;
		num2 = temp;
		System.out.println("交换后的结果：");
		System.out.println("num1:" + num1);
		System.out.println("num2:" + num2);
	}

}
